Test Series - java script

Test Number 33/92

Q: Which syntax is used to describe elements in CSS?
A. Protectors
B. Selectors
C. Both Protectors and Selectors
D. Protectors or Selectors
Solution: CSS stylesheets have a very powerful syntax, known as selectors, for describing elements or sets of elements within a document.
Q: What does the following JavaScript code snippet mean?

#log>span
A. Span child after log declaration
B. Specific span child of id greater than log
C. Span child less than log
D. Any span child of the element with id as log
Solution: The above code snippet means that any span child of the element with id=”log”.
Q: Which of the following is the ultimate element selection method?
A. querySelectorAll()
B. querySelector()
C. queryAll()
D. query()
Solution: querySelectorAll() is the ultimate element selection method: it is a very powerful technique by which client-side JavaScript programs can select the document elements that they are going to manipulate.
Q: Which of the following is the Web application equivalent to querySelectorAll()?
A. #()
B. &()
C. $()
D. !()
Solution: Web applications based on jQuery use a portable, cross-browser equivalent to querySelectorAll() named $().
Q: The C in CSS stands for _______________
A. Continuous
B. Cascaded
C. Contentional
D. Cascading
Solution: The C in CSS stands for “cascading”. This term indicates that the style rules that apply to any given element in a document can come from a “cascade” of different sources.
Q: The first version of CSS is _____________
A. CSS1
B. CSS2
C. CSS3
D. CSS
Solution: The first version of CSS is CSS1. It was officially released in the year 1996.
Q: Which of the following is not an example of a Shortcut Property?
A. border
B. font
C. text
D. value
Solution: border, font & text are shortcut properties. For example, the font-family, font-size, font-style, and font-weight properties can all be set at once using a single font property with a compound value:
font: bold italic 24pt helvetica;
Q: Which of the following is the default positioning elements with CSS?
A. relative
B. static
C. absolute
D. fixed
Solution: static is the default value and specifies that the element is positioned according to the normal flow of document content (for most Western languages, this is left to right and top to bottom).
Q: Which property lays the element according to the normal flow?
A. relative
B. absolute
C. fixed
D. static
Solution: When the position property is set to relative, an element is laid out according to the normal flow, and its position is then adjusted relative to its position in the normal flow.
Q: Which of the following property allows you to specify an element’s position with respect to the browser window?
A. relative
B. fixed
C. static
D. absolute
Solution: The fixed value allows you to specify an element’s position with respect to the browser window. Elements with fixed positioning are always visible and do not scroll with the rest of the document. Like absolutely positioned elements, fixed-position elements are independent of all others and are not part of the document flow.

You Have Score    /10